package com.pkk.cloud.support.oauth2.config.integration;

/**
 * @author peikunkun<br>
 * @version V1.0<br>
 * @Title: 集成身份验证上下文<br>
 * @Description: <><br>
 * @date 2020/3/18 0018 下午 12:02<br>
 * @URL:[]
 */
public class IntegrationAuthenticationContext {

  private static ThreadLocal<IntegrationAuthentication> holder = new ThreadLocal<>();

  public static void set(IntegrationAuthentication integrationAuthentication) {
    holder.set(integrationAuthentication);
  }

  public static IntegrationAuthentication get() {
    return holder.get();
  }

  public static void clear() {
    holder.remove();
  }
}
